473,416 Members | 1,566 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,416 software developers and data experts.

insert TAB

ddtpmyra
333 100+
Hi Im having dificulty of controlling the display inside my tab let say I have two tabs A and B, what I have on tab A also shows on tab B although I used close tags at the end? Can anyone take a look what Im missing?

Expand|Select|Wrap|Line Numbers
  1.   echo '
  2.       </table>' . ( $useTabs ? '
  3.     </div>' : '
  4.     </fieldset>' ) . '
  5.  
  6. <!-- REPEATING INFO -->';
  7.   if ( $DISABLE_RECAP_FIELD != 'Y' ) {
  8.     echo ( $useTabs ? '
  9.     <a name="tabrecap"></a>
  10.     <div id="tabscontent_recap">' : '
  11.     <fieldset>
  12.       <legend>' . translate ( 'Recap' ) . '</legend>' ) . '
  13.       <table border="0" cellspacing="0" cellpadding="3" summary="">
  14.         <tr>
  15.       <td class="tooltip" title="' . tooltip ( 'repeat-type-help' )
  16.      . '"><label for="rpttype">' . translate ( 'Type' ) . ':</label></td>
  17.           </td>
  18.       </tr>
  19.     </table>' . ( $useTabs ? '
  20.     </div> <!-- End tabscontent_recap -->' : '
  21.     </fieldset>' );
  22.   }
  23.  
  24.  
Mar 10 '09 #1
7 5468
TheServant
1,168 Expert 1GB
Don't know why this was moved to html-css? Anyway, what is the variable $useTabs? I haven't seen that " ? ' " syntax before, but it is quite possibley just a form of something I have never tried.

Once your page has printed, have a look at the HTML output and see html-wise what's going wrong and then you can fix your PHP.
Mar 10 '09 #2
Markus
6,050 Expert 4TB
Because this is an HTML problem. PHP servers the HTML, yes, but it's an error with his HTML - not PHP.

Anyway, he's using the ternary operator syntax ( ( condition ) ? true : false )
Mar 10 '09 #3
TheServant
1,168 Expert 1GB
Thanks Markus. I just saw that there is still some conditional html output so I didn't rule out PHP error. Speaking of which, ddtpmyra, have you tried what I suggested?
Mar 11 '09 #4
ddtpmyra
333 100+
Here's what I got the text 'Hello' still showing on other tabs

PHP

Expand|Select|Wrap|Line Numbers
  1.   if ( $DISABLE_RECAP_FIELD != 'Y' ) {
  2.     echo ( $useTabs ? '
  3.     <a name="tabrecap"></a>
  4.     <div id="tabscontent_recap">' : '
  5.     <fieldset>
  6.       <legend>' . translate ( 'Recap' ) . '</legend>' ) . '
  7.       <table border="0" cellspacing="0" cellpadding="3" summary="">
  8.         <tr>
  9.       <td> Hello </td>
  10.       </tr>
  11.     </table>' . ( $useTabs ? '
  12.     </div> <!-- End tabscontent_recap -->' : '
  13.     </fieldset>' );
  14.   }
  15.  
  16.  

HTML

Expand|Select|Wrap|Line Numbers
  1. <!-- REPEATING INFO -->
  2.     <a name="tabrecap"></a>
  3.     <div id="tabscontent_recap">
  4.       <table border="0" cellspacing="0" cellpadding="3" summary="">
  5.         <tr>
  6.       <td> Hello </td>
  7.       </tr>
  8.     </table>
  9.     </div> <!-- End tabscontent_recap -->
  10.  
Mar 12 '09 #5
TheServant
1,168 Expert 1GB
I only see one "Hello" table in your html? What do you mean "repeating info"?

In your PHP, you only have one code generation which is run if $DISABLE_RECAP_FIELD != 'Y' so I don't see why you would have any "Hello" output unless it is running again? Need more info.
Mar 12 '09 #6
ddtpmyra
333 100+
Hi sorry for not explaining the problem clearly.

I created like three sets of tabs with different name and different txt inside. But the texts for each tabs are displayed on every tabs. I thought using </div> and </fieldset> it should end each tabs contents, is there any ways to do this?
Mar 13 '09 #7
David Laakso
397 Expert 256MB
No clue here as far as whatever that stuff is you got. The below is html/css to yield a page with four tabs on it. Obviously, you'll want to delete one, as I guess you only need three.

Please make the tabbed page, and move it and your question, to whatever the appropriate board is on this forum, in order to attach whatever the behavior is wish your three tabs to perform for you (if any).

Expand|Select|Wrap|Line Numbers
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  2.     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  3.  
  4. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
  5. <head>
  6.     <title>Tabs </title>
  7.     <style type="text/css" media="all">
  8.  
  9.     body {
  10.         font: 1em arial, helvetica, sans-serif;
  11.     }
  12.  
  13.     #header ul {
  14.         list-style: none;
  15.         padding: 0;
  16.         margin: 0;
  17.     }
  18.  
  19.     #header li {
  20.         display: inline;
  21.         border: 1px solid;
  22.         border-bottom-width: 0;
  23.         margin: 0 0.5em 0 0;
  24.     }
  25.  
  26.     #header li a {
  27.         padding: 0 1em;
  28.     }
  29.  
  30.     #header #selected {
  31.         padding-bottom: 1px;
  32.         background: white;
  33.     }
  34.  
  35.     #content {
  36.         border: 1px solid;
  37.     }
  38.  
  39.     </style>
  40. </head>
  41.  
  42. <body>
  43.  
  44. <div id="header">
  45.  
  46. <h1>Tabs</h1>
  47.  
  48. <ul>
  49.     <li><a href="#">This</a></li>
  50.     <li id="selected"><a href="#">That</a></li>
  51.     <li><a href="#">The Other</a></li>
  52.     <li><a href="#">Banana</a></li>
  53. </ul>
  54.  
  55. </div>
  56.  
  57. <div id="content">
  58.     <p>Ispum schmipsum.</p>
  59. </div>
  60.  
  61. </body>
  62. </html>
  63.  
  64.  
  65.  
Mar 13 '09 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Howard Hinnant | last post by:
I recently asked for a survey of multimap insert with hint behavior, in support of a paper I'm writing concerning lwg issue 233. My sincere thanks to Beman Dawes, Raoul Gough, Russell Hind, Bronek...
6
by: Mark P | last post by:
Some time ago I posted here about inserting into a set with a hint: ...
14
by: serge | last post by:
I have a scenario where two tables are in a One-to-Many relationship and I need to move the data from the Many table to the One table so that it becomes a One-to-One relationship. I need to...
2
by: Ford Desperado | last post by:
I've been reading the docs and playing around, but I'm still not getting the difference. For instance, create table a(i int check(i>0)) create table a_src(i int) go create unique index ai on...
16
by: Philip Boonzaaier | last post by:
I want to be able to generate SQL statements that will go through a list of data, effectively row by row, enquire on the database if this exists in the selected table- If it exists, then the colums...
4
by: Chris Kratz | last post by:
Hello all, We have run into what appears to be a problem with rules and subselects in postgres 7.4.1. We have boiled it down to the following test case. If anyone has any thoughts as to why...
2
by: Geoffrey KRETZ | last post by:
Hello, I'm wondering if the following behaviour is the correct one for PostGreSQL (7.4 on UNIX). I've a table temp_tab with 5 fields (f1,f2,f3,...),and I'm a launching the following request :...
3
by: MP | last post by:
Hi Posted this several hours ago to another ng but it never showed up thought i'd try here. using vb6, ado, .mdb, jet4.0, no access given table tblJob with field JobNumber text(10) 'The...
6
by: lenygold via DBMonster.com | last post by:
Hi everybody: What is the best way to I have 10 tables with similar INSERT requiremnts. INSERT INTO ACSB.VAATAFAE WITH AA(AA_TIN, AA_FILE_SOURCE_CD, .AA_TIN_TYP) AS ( SELECT AA_TIN,...
1
by: EJO | last post by:
with sql 2000 enterprise Trying to build a stored procedure that will take the rows of a parent table, insert them into another table as well as the rows from a child table to insert into...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.